home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 4
/
Aminet 4 - November 1994.iso
/
aminet
/
comm
/
term
/
vltj5867.lha
/
VLT
/
rexx
/
VLTPhoneBook.vlt
< prev
next >
Wrap
Text File
|
1994-03-27
|
4KB
|
121 lines
/** VLTPhoneBook.vlt
*
* This program brings up the main VLT PhoneBook requester.
*
* By W.G.J. Langeveld, February 1992.
*
* This program really wants to be called *from inside* VLT, so assign
* ~@VLTPhoneBook.vlt to your favorite function key, or select it from
* VLT's menu.
*
* Add the libraries if they're not there yet.
*
**/
if show("l", "rexxarplib.library") = 0 then do
check = addlib('rexxsupport.library', 0, -30, 0)
check = addlib('rexxarplib.library', 0, -30, 0)
end
/*
* The following sequence determines both VLT's screen and port name,
* and also gets the number screen rows and columns.
*/
vltport = address()
cols = ScreenCols(vltport)
if cols == -1 then do
vltscreen = ""
cols = ScreenCols()
rows = ScreenRows()
end
else do
vltscreen = vltport
rows = ScreenRows(vltscreen)
end
/*
* Set up a host. This time, send all messages to VLT.
*/
address AREXX "'x = CreateHost(VLTPHONEBOOK, "vltport", "vltscreen")'"
/*
* Wait until it is ready.
*/
do i = 1
if showlist('p', VLTPHONEBOOK) ~= 0 then leave
call delay 30
end
call SetReqColor(VLTPHONEBOOK, BACKGROUNDPEN, 0)
/*
* Open the window
*/
idcmp = 'CLOSEWINDOW+GADGETUP+MENUPICK'
flags = 'WINDOWCLOSE+WINDOWDRAG+WINDOWDEPTH+ACTIVATE'
call OpenWindow(VLTPHONEBOOK, cols - 260, rows - 175, 240, 168, idcmp, ,
flags, "VLTPhoneBook")
call SetNotify(VLTPHONEBOOK, CLOSEWINDOW, VLTPHONEBOOK)
/*
* Add the gadgets
*/
call AddMenu(VLTPHONEBOOK, "Commands")
call AddItem(VLTPHONEBOOK, " Select VLT PhoneBook...", ,
"@VLTPhoneSetup.rexx", "P", 0)
call AddItem(VLTPHONEBOOK, " Create PhoneBook Entry...", ,
"@VLTPhoneModify.rexx New", "N", 0)
call AddItem(VLTPHONEBOOK, " Modify PhoneBook Entry...", ,
"@VLTPhoneModify.rexx Modify", "M", 0)
call AddItem(VLTPHONEBOOK, " Delete PhoneBook Entry...", ,
"@VLTPhoneDelete.rexx", "K", 0)
call AddItem(VLTPHONEBOOK, " Show PhoneBook Entry...", ,
"@VLTPhoneShow.rexx", "V", 0)
call AddItem(VLTPHONEBOOK, " Select Entries to Dial...", ,
"@VLTPhoneSelect.rexx", "S", 0)
call AddItem(VLTPHONEBOOK, " Start Dialing Sequence", ,
"@@VLTPhoneDial.rexx "vltport, "D", 0)
call AddItem(VLTPHONEBOOK, " Resume Dialing Sequence", ,
"cancel $vltphone_wait resume", "R", 0)
call AddItem(VLTPHONEBOOK, " Cancel Dialing Sequence", ,
"cancel $vltphone_wait abort", "C", 0)
call AddItem(VLTPHONEBOOK, " Quit", ,
"rx (address VLTPHONEBOOK QUIT)", "Q", 0)
call AddGadget(VLTPHONEBOOK, 10, 20, 1, " Select VLT PhoneBook... ", ,
"@VLTPhoneSetup.rexx")
call AddGadget(VLTPHONEBOOK, 10, 40, 2, " Create PhoneBook Entry... ", ,
"@VLTPhoneModify.rexx New")
call AddGadget(VLTPHONEBOOK, 10, 54, 3, " Modify PhoneBook Entry... ", ,
"@VLTPhoneModify.rexx Modify")
call AddGadget(VLTPHONEBOOK, 10, 68, 4, " Delete PhoneBook Entry... ", ,
"@VLTPhoneDelete.rexx")
call AddGadget(VLTPHONEBOOK, 10, 82, 5, " Show PhoneBook Entry... ", ,
"@VLTPhoneShow.rexx")
call AddGadget(VLTPHONEBOOK, 10, 102, 6, " Select Entries to Dial... ", ,
"@VLTPhoneSelect.rexx")
call AddGadget(VLTPHONEBOOK, 10, 122, 7, " Start Dialing Sequence ", ,
"@@VLTPhoneDial.rexx "vltport)
call AddGadget(VLTPHONEBOOK, 10, 136, 8, " Resume Dialing Sequence ", ,
"cancel $vltphone_wait resume")
call AddGadget(VLTPHONEBOOK, 10, 150, 9, " Cancel Dialing Sequence ", ,
"cancel $vltphone_wait abort")
/*
* That's it. All the rest is done either directly or in other programs
*/
exit